//
//  UITableView+EmptyData.m
//  Only Love
//
//  Created by xalo on 16/5/7.
//  Copyright © 2016年 海城. All rights reserved.
//

#import "UITableView+EmptyData.h"

@implementation UITableView (EmptyData)

-(NSInteger)disPlayMessage:(NSString *)title withArrayCount:(NSInteger)count{
    
    if (count == 0) {
        
        self.backgroundView = ({
            
            UILabel *label = [[UILabel alloc] init];
            label.text = title;
            label.textAlignment = NSTextAlignmentCenter;
            label.alpha = 0.5;
            label;
        });
        
        
    }else{
        
        self.backgroundView = nil;
        
    }
    return count;
}
@end
